<template>
    <div>
        <el-form :inline="true" :model="formInline" class="demo-form-inline1">
            <el-form-item label="客户姓名">
                <el-input v-model="formInline.user" placeholder="请输入客户姓名"></el-input>
            </el-form-item>
            <el-form-item label="客户手机">
                <el-input v-model="formInline.user" placeholder="请输入客户手机号码"></el-input>
            </el-form-item>
            <el-form-item label="归属人">
                <el-input v-model="formInline.user" placeholder="请输入线索归属人"></el-input>
            </el-form-item>
            <el-form-item label="渠道来源">
                <el-select v-model="formInline.region" placeholder="渠道来源">
                    <el-option label="区域一" value="shanghai"></el-option>
                    <el-option label="区域二" value="beijing"></el-option>
                </el-select>
            </el-form-item>
        </el-form>
        <el-form :inline="true" :model="formInline" class="demo-form-inline2">
            <el-form-item label="线索状态">
                <el-select v-model="formInline.region" placeholder="线索状态">
                    <el-option label="区域一" value="shanghai"></el-option>
                    <el-option label="区域二" value="beijing"></el-option>
                </el-select>
            </el-form-item>
            <div class="block">
                <span class="demonstration">跟进时间</span> &nbsp;
                <el-date-picker v-model="value2" type="daterange" align="right" unlink-panels range-separator="-"
                    start-placeholder="开始日期" end-placeholder="结束日期" :picker-options="pickerOptions">
                </el-date-picker>
            </div>
            <el-form-item>
                <el-button type="primary" icon="el-icon-search">搜索</el-button>
            </el-form-item>
            <el-form-item>
                <el-button icon="el-icon-refresh">重置</el-button>
            </el-form-item>

        </el-form>
        <el-form :inline="true" :model="formInline" class="demo-form-inline2">
            <el-form-item>
                <el-button type="primary" plain icon="el-icon-plus">新增</el-button>
            </el-form-item>
            <el-form-item>
                <el-button type="success" plain icon="el-icon-edit-outline">修改</el-button>
            </el-form-item>
            <el-form-item>
                <el-button type="danger" plain icon="el-icon-delete-solid">删除</el-button>
            </el-form-item>
        </el-form>
        <el-table ref="multipleTable" :data="tableData" tooltip-effect="dark" style="width: 100%"
            @selection-change="handleSelectionChange">
            <el-table-column type="selection" width="55">
            </el-table-column>
            <el-table-column label="线索编号" width="120">
                <template slot-scope="scope">{{ scope.row.date }}</template>
            </el-table-column>
            <el-table-column prop="name" label="客户姓名" width="120">
            </el-table-column>
            <el-table-column prop="phone" label="手机号码" width="120" show-overflow-tooltip>
            </el-table-column>
            <el-table-column prop="laiyuau" label="渠道来源" width="120" show-overflow-tooltip>
            </el-table-column>
            <el-table-column prop="time" label="创建时间" width="180">
            </el-table-column>
            <el-table-column prop="tag" label="在线状态" width="100"
                :filters="[{ text: '已分配', value: '已分配' }, { text: '跟进中', value: '跟进中' }]" :filter-method="filterTag"
                filter-placement="bottom-end">
                <template slot-scope="scope">
                    <el-tag :type="scope.row.tag === '已分配' ? 'primary' : 'success'" disable-transitions>{{ scope.row.tag
                    }}</el-tag>
                </template>
            </el-table-column>
            <el-table-column prop="timen" label="下次跟进时间" width="180">
            </el-table-column>
            <el-table-column label="操作">
                <template slot-scope="scope">
                    <el-button size="mini" type="primary" @click="handleEdit(scope.$index, scope.row)"
                        icon="el-icon-edit"></el-button>
                    <el-button size="mini" type="danger" @click="handleDelete(scope.$index, scope.row)"
                        icon="el-icon-delete"></el-button>
                </template>
            </el-table-column>
        </el-table>
        <div class="block">
            <el-pagination @size-change="handleSizeChange" @current-change="handleCurrentChange"
                :current-page="currentPage4" :page-sizes="[100, 200, 300, 400]" :page-size="100"
                layout="total, sizes, prev, pager, next, jumper" :total="400" background="">
            </el-pagination>
        </div>
    </div>
</template>

<script>
export default {
   
    data() {
        return {
            formInline: {
                user: '',
                region: ''
            },
            tableData: [{
                date: '2016-05-03',
                name: '王小虎',
                phone: '12213520',
                laiyuau: '线下地推',
                time: '2025-04-19 19:01:19',
                tag: "已分配",
                timen: '2025-04-30 19:01:19',

            }, {
                date: '2016-05-03',
                name: '王小虎',
                phone: '12213520',
                laiyuau: '线下地推',
                time: '2025-04-19 19:01:19',
                tag: "已分配",
                timen: '2025-04-30 19:01:19',
            }, {
                date: '2016-05-03',
                name: '王小虎',
                phone: '12213520',
                laiyuau: '线下地推',
                time: '2025-04-19 19:01:19',
                tag: "已分配",
                timen: '2025-04-30 19:01:19',
            }, {
                date: '2016-05-03',
                name: '王小虎',
                phone: '12213520',
                laiyuau: '线下地推',
                time: '2025-04-19 19:01:19',
                tag: "已分配",
                timen: '2025-04-30 19:01:19',
            }, {
                date: '2016-05-03',
                name: '王小虎',
                phone: '12213520',
                laiyuau: '线下地推',
                time: '2025-04-19 19:01:19',
                tag: "已分配",
                timen: '2025-04-30 19:01:19',
            }, {
                date: '2016-05-03',
                name: '王小虎',
                phone: '12213520',
                laiyuau: '线下地推',
                time: '2025-04-19 19:01:19',
                tag: "已分配",
                timen: '2025-04-30 19:01:19',
            }, {
                date: '2016-05-03',
                name: '王小虎',
                phone: '12213520',
                laiyuau: '线下地推',
                time: '2025-04-19 19:01:19',
                tag: "已分配",
                timen: '2025-04-30 19:01:19',
            }],
            multipleSelection: []
        }
    },
    methods: {
        onSubmit() {
            console.log('submit!');
        }
    },
    name:"index",
    created(){
        
    },

}
</script>

<style lang="scss" scoped>
.demo-form-inline2 {
    display: flex;

}

.demo-form-inline1 {
    display: flex;

}

.el-form-item {
    margin-right: 40px;
}

.block {
    margin-right: 40px;
}
</style>